<template>
  <div class="bg_box">
    <!-- 头部区域 start -->
    <div class="header">
      <span class="topTbas" @click="$router.push({ name: 'Home' })">首页</span>
      <span>MayiGenerator-Echarts生成器</span>
      <span></span>
    </div>

    <!-- 内容区域 -->
    <div class="content">
      <!-- 左侧区域 -->
      <div class="left">
        <el-scrollbar class="left-scrollbar">
          <div class="echartsList_warp">
            <div v-for="(item, index) in echartsList" :key="index" class="item">
              {{ item.name }}
            </div>
          </div>
        </el-scrollbar>
      </div>
      <!-- 中间区域 -->
      <div class="center">2</div>
      <!-- 右侧区域 -->
      <div class="right">3</div>
    </div>
  </div>
</template>
<!-- 头部区域 end -->
<script>
import { echartsList } from "./config/EchartsJson.js";
export default {
  data() {
    return {
      echartsList
    };
  },
  methods: {}
};
</script>

<style lang="scss" scoped>
.bg_box {
  background-color: rgb(255, 255, 255);
  .header {
    width: 100%;
    height: 56px;
    background: #6a66f6;
    color: #fff;
    line-height: 56px;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: space-around;
    .topTbas {
      cursor: pointer;
    }
  }
  .content {
    margin-top: 10px;
    height: calc(100% - 66px);
    display: flex;
    .left {
      .left-scrollbar {
        height: 100%;
        overflow: hidden;
        .echartsList_warp {
          width: 100%;

          .item {
            padding: 8px 12px;
            // width: calc(50% - 6px);
            margin: 10px;
            height: 36px;
            cursor: pointer;
            border: 1px solid #d8d8d8;
            &:hover {
              border-color: #6a66f6;
              background: #6a66f6;
              color: #e8e8e8;
              font-weight: bold;
            }
          }
        }
      }
      height: 100%;
      width: 300px;
      box-shadow: 0 0 1px 1px #ccc;
    }
    .center {
      height: 100%;
      width: 100%;
      margin: 0 8px 0;
      box-shadow: 0 0 1px 1px #ccc;
    }
    .right {
      height: 100%;
      width: 300px;
      box-shadow: 0 0 1px 1px #ccc;
    }
  }
}
</style>
